API: remove gdk_draw_arc()
authorBenjamin Otte <otte@redhat.com>
Wed, 14 Jul 2010 12:07:21 +0000 (14:07 +0200)
committerBenjamin Otte <otte@redhat.com>
Tue, 10 Aug 2010 19:02:27 +0000 (21:02 +0200)
13 files changed:
docs/reference/gdk/gdk3-sections.txt
docs/reference/gdk/tmpl/drawing.sgml
docs/reference/gtk/tmpl/gtkdrawingarea.sgml
gdk/directfb/gdkdrawable-directfb.c
gdk/gdk.symbols
gdk/gdkdraw.c
gdk/gdkdrawable.h
gdk/gdkoffscreenwindow.c
gdk/gdkpixmap.c
gdk/gdkwindow.c
gdk/quartz/gdkdrawable-quartz.c
gdk/win32/gdkdrawable-win32.c
gdk/x11/gdkdrawable-x11.c

index beb3b3731b7b6359042acea10816952c7cfbc1eb..12d2f3735c35bf8b88c0acb308830481420952a7 100644 (file)
@@ -341,7 +341,6 @@ gdk_draw_lines
 gdk_draw_segments
 GdkSegment
 gdk_draw_rectangle
-gdk_draw_arc
 gdk_draw_polygon
 gdk_draw_trapezoids
 GdkTrapezoid
index 20f89ef3e7f19b2e0475933ce38d94aaaa992fe2..1ada3dde3f55ac7b7c65836219789944308b46c1 100644 (file)
@@ -208,21 +208,6 @@ function.
 @height: 
 
 
-<!-- ##### FUNCTION gdk_draw_arc ##### -->
-<para>
-</para>
-
-@drawable: 
-@gc: 
-@filled: 
-@x: 
-@y: 
-@width: 
-@height: 
-@angle1: 
-@angle2: 
-
-
 <!-- ##### FUNCTION gdk_draw_polygon ##### -->
 <para>
 </para>
index 1edf19d42739b2d2b3f59b5f3d54dfcf2f5aa1bb..2ec329cc835ea13a40849066c7ea433215fe1d66 100644 (file)
@@ -55,11 +55,14 @@ that drawing is implicitly clipped to the exposed area.
 gboolean
 expose_event_callback (GtkWidget *widget, GdkEventExpose *event, gpointer data)
 {
-  gdk_draw_arc (widget->window,
-                widget->style->fg_gc[gtk_widget_get_state (widget)],
-                TRUE,
-                0, 0, widget->allocation.width, widget->allocation.height,
-                0, 64 * 360);
+  cairo_t *cr;
+  
+  cr = gdk_cairo_create (event->window);
+
+  cairo_set_source_rgb (cr, 0.0, 0.0, 1.0);
+  cairo_paint (cr);
+
+  cairo_destroy (cr);
  
   return TRUE;
 }
index 167d51a305a38c583073666ef32e0b5fc9b34954..d3f55f705b9572bca3ec3e250945f18346ed9253 100644 (file)
@@ -553,20 +553,6 @@ gdk_directfb_draw_rectangle (GdkDrawable *drawable,
     }
 }
 
-static void
-gdk_directfb_draw_arc (GdkDrawable *drawable,
-                       GdkGC       *gc,
-                       gint         filled,
-                       gint         x,
-                       gint         y,
-                       gint         width,
-                       gint         height,
-                       gint         angle1,
-                       gint         angle2)
-{
-  D_UNIMPLEMENTED();
-}
-
 static void
 gdk_directfb_draw_polygon (GdkDrawable *drawable,
                            GdkGC       *gc,
@@ -987,7 +973,6 @@ gdk_drawable_impl_directfb_class_init (GdkDrawableImplDirectFBClass *klass)
 
   drawable_class->create_gc      = _gdk_directfb_gc_new;
   drawable_class->draw_rectangle = gdk_directfb_draw_rectangle;
-  drawable_class->draw_arc       = gdk_directfb_draw_arc;
   drawable_class->draw_polygon   = gdk_directfb_draw_polygon;
   drawable_class->draw_drawable  = gdk_directfb_draw_drawable;
   drawable_class->draw_points    = gdk_directfb_draw_points;
index 31b9496f14e5c0647e93bd95efda6348bc561f97..81348c350747dfd3e773f6896f563f8bb2766230 100644 (file)
@@ -549,7 +549,6 @@ gdk_drawable_get_type G_GNUC_CONST
 gdk_drawable_get_visible_region
 gdk_drawable_get_visual
 gdk_drawable_set_colormap
-gdk_draw_arc
 gdk_draw_drawable
 gdk_draw_glyphs
 gdk_draw_glyphs_transformed
index e8a0a170c3522443581dbd6248f9ab6eff8644c8..2a5c36b71716e4fb6ba9cb5885b0e18bded92ca9 100644 (file)
@@ -323,55 +323,6 @@ gdk_draw_rectangle (GdkDrawable *drawable,
                                                      width, height);
 }
 
-/**
- * gdk_draw_arc:
- * @drawable: a #GdkDrawable (a #GdkWindow or a #GdkPixmap).
- * @gc: a #GdkGC.
- * @filled: %TRUE if the arc should be filled, producing a 'pie slice'.
- * @x: the x coordinate of the left edge of the bounding rectangle.
- * @y: the y coordinate of the top edge of the bounding rectangle.
- * @width: the width of the bounding rectangle.
- * @height: the height of the bounding rectangle.
- * @angle1: the start angle of the arc, relative to the 3 o'clock position,
- *     counter-clockwise, in 1/64ths of a degree.
- * @angle2: the end angle of the arc, relative to @angle1, in 1/64ths 
- *     of a degree.
- * 
- * Draws an arc or a filled 'pie slice'. The arc is defined by the bounding
- * rectangle of the entire ellipse, and the start and end angles of the part 
- * of the ellipse to be drawn.
- **/
-void
-gdk_draw_arc (GdkDrawable *drawable,
-             GdkGC       *gc,
-             gboolean     filled,
-             gint         x,
-             gint         y,
-             gint         width,
-             gint         height,
-             gint         angle1,
-             gint         angle2)
-{  
-  g_return_if_fail (GDK_IS_DRAWABLE (drawable));
-  g_return_if_fail (GDK_IS_GC (gc));
-
-  if (width < 0 || height < 0)
-    {
-      gint real_width;
-      gint real_height;
-      
-      gdk_drawable_get_size (drawable, &real_width, &real_height);
-
-      if (width < 0)
-        width = real_width;
-      if (height < 0)
-        height = real_height;
-    }
-
-  GDK_DRAWABLE_GET_CLASS (drawable)->draw_arc (drawable, gc, filled,
-                                               x, y, width, height, angle1, angle2);
-}
-
 /**
  * gdk_draw_polygon:
  * @drawable: a #GdkDrawable (a #GdkWindow or a #GdkPixmap).
index fcad892f06165cff7b053957888e64d889440cd5..84a981ef4751cbd3edcd87db8956897507b37858 100644 (file)
@@ -68,15 +68,6 @@ struct _GdkDrawableClass
                          gint          y,
                          gint          width,
                          gint          height);
-  void (*draw_arc)       (GdkDrawable  *drawable,
-                         GdkGC        *gc,
-                         gboolean      filled,
-                         gint          x,
-                         gint          y,
-                         gint          width,
-                         gint          height,
-                         gint          angle1,
-                         gint          angle2);
   void (*draw_polygon)   (GdkDrawable  *drawable,
                          GdkGC        *gc,
                          gboolean      filled,
@@ -218,15 +209,6 @@ void gdk_draw_rectangle (GdkDrawable      *drawable,
                         gint              y,
                         gint              width,
                         gint              height);
-void gdk_draw_arc       (GdkDrawable      *drawable,
-                        GdkGC            *gc,
-                        gboolean          filled,
-                        gint              x,
-                        gint              y,
-                        gint              width,
-                        gint              height,
-                        gint              angle1,
-                        gint              angle2);
 void gdk_draw_polygon   (GdkDrawable      *drawable,
                         GdkGC            *gc,
                         gboolean          filled,
index 92c4905c489d1bebd0036baac1e2b7df9932a0b4..91a438194668ba856f45c4de56b4ab103f9ed30b 100644 (file)
@@ -323,32 +323,6 @@ gdk_offscreen_window_draw_rectangle (GdkDrawable  *drawable,
 
 }
 
-static void
-gdk_offscreen_window_draw_arc (GdkDrawable  *drawable,
-                              GdkGC           *gc,
-                              gboolean filled,
-                              gint             x,
-                              gint             y,
-                              gint             width,
-                              gint             height,
-                              gint             angle1,
-                              gint             angle2)
-{
-  GdkOffscreenWindow *offscreen = GDK_OFFSCREEN_WINDOW (drawable);
-  GdkDrawable *real_drawable = get_real_drawable (offscreen);
-
-  gdk_draw_arc (real_drawable,
-               gc,
-               filled,
-               x,
-               y,
-               width,
-               height,
-               angle1,
-               angle2);
-  add_damage (offscreen, x, y, width, height, !filled);
-}
-
 static void
 gdk_offscreen_window_draw_polygon (GdkDrawable  *drawable,
                                   GdkGC               *gc,
@@ -1109,7 +1083,6 @@ gdk_offscreen_window_class_init (GdkOffscreenWindowClass *klass)
   drawable_class->get_composite_drawable = gdk_offscreen_window_get_composite_drawable;
 
   drawable_class->draw_rectangle = gdk_offscreen_window_draw_rectangle;
-  drawable_class->draw_arc = gdk_offscreen_window_draw_arc;
   drawable_class->draw_polygon = gdk_offscreen_window_draw_polygon;
   drawable_class->draw_drawable_with_src = gdk_offscreen_window_draw_drawable;
   drawable_class->draw_points = gdk_offscreen_window_draw_points;
index 8319977380a9eb951aa29e7e921e6d62e3be5d07..c3558601ac74a27ccf23df37b3b8ac46a860c737 100644 (file)
@@ -41,15 +41,6 @@ static void   gdk_pixmap_draw_rectangle (GdkDrawable     *drawable,
                                         gint             y,
                                         gint             width,
                                         gint             height);
-static void   gdk_pixmap_draw_arc       (GdkDrawable     *drawable,
-                                        GdkGC           *gc,
-                                        gboolean         filled,
-                                        gint             x,
-                                        gint             y,
-                                        gint             width,
-                                        gint             height,
-                                        gint             angle1,
-                                        gint             angle2);
 static void   gdk_pixmap_draw_polygon   (GdkDrawable     *drawable,
                                         GdkGC           *gc,
                                         gboolean         filled,
@@ -155,7 +146,6 @@ gdk_pixmap_class_init (GdkPixmapObjectClass *klass)
 
   drawable_class->create_gc = gdk_pixmap_create_gc;
   drawable_class->draw_rectangle = gdk_pixmap_draw_rectangle;
-  drawable_class->draw_arc = gdk_pixmap_draw_arc;
   drawable_class->draw_polygon = gdk_pixmap_draw_polygon;
   drawable_class->draw_drawable_with_src = gdk_pixmap_draw_drawable;
   drawable_class->draw_points = gdk_pixmap_draw_points;
@@ -258,25 +248,6 @@ gdk_pixmap_draw_rectangle (GdkDrawable *drawable,
                       x, y, width, height);
 }
 
-static void
-gdk_pixmap_draw_arc (GdkDrawable *drawable,
-                    GdkGC       *gc,
-                    gboolean     filled,
-                    gint         x,
-                    gint         y,
-                    gint         width,
-                    gint         height,
-                    gint         angle1,
-                    gint         angle2)
-{
-  GdkPixmapObject *private = (GdkPixmapObject *)drawable;
-
-  _gdk_gc_remove_drawable_clip (gc);  
-  gdk_draw_arc (private->impl, gc, filled,
-                x, y,
-                width, height, angle1, angle2);
-}
-
 static void
 gdk_pixmap_draw_polygon (GdkDrawable *drawable,
                         GdkGC       *gc,
index ef1822be1069f9ffcbb3bff9f43c08737918a37f..de120c14bfa592f7a31615ca58ecc4d0529363b7 100644 (file)
@@ -236,15 +236,6 @@ static void   gdk_window_draw_rectangle (GdkDrawable     *drawable,
                                         gint             y,
                                         gint             width,
                                         gint             height);
-static void   gdk_window_draw_arc       (GdkDrawable     *drawable,
-                                        GdkGC           *gc,
-                                        gboolean         filled,
-                                        gint             x,
-                                        gint             y,
-                                        gint             width,
-                                        gint             height,
-                                        gint             angle1,
-                                        gint             angle2);
 static void   gdk_window_draw_polygon   (GdkDrawable     *drawable,
                                         GdkGC           *gc,
                                         gboolean         filled,
@@ -470,7 +461,6 @@ gdk_window_class_init (GdkWindowObjectClass *klass)
 
   drawable_class->create_gc = gdk_window_create_gc;
   drawable_class->draw_rectangle = gdk_window_draw_rectangle;
-  drawable_class->draw_arc = gdk_window_draw_arc;
   drawable_class->draw_polygon = gdk_window_draw_polygon;
   drawable_class->draw_drawable_with_src = gdk_window_draw_drawable;
   drawable_class->draw_points = gdk_window_draw_points;
@@ -3969,27 +3959,6 @@ gdk_window_draw_rectangle (GdkDrawable *drawable,
   END_DRAW;
 }
 
-static void
-gdk_window_draw_arc (GdkDrawable *drawable,
-                    GdkGC       *gc,
-                    gboolean     filled,
-                    gint         x,
-                    gint         y,
-                    gint         width,
-                    gint         height,
-                    gint         angle1,
-                    gint         angle2)
-{
-  if (GDK_WINDOW_DESTROYED (drawable))
-    return;
-
-  BEGIN_DRAW;
-  gdk_draw_arc (impl, gc, filled,
-               x - x_offset, y - y_offset,
-               width, height, angle1, angle2);
-  END_DRAW;
-}
-
 static void
 gdk_window_draw_polygon (GdkDrawable *drawable,
                         GdkGC       *gc,
index 9e115303d3ac59e7435d8f2a3650dfdf983142fc..6c77bb4874355a5d042c1096ba30f5f258ba0365 100644 (file)
@@ -184,80 +184,6 @@ gdk_quartz_draw_rectangle (GdkDrawable *drawable,
   gdk_quartz_drawable_release_context (drawable, context);
 }
 
-static void
-gdk_quartz_draw_arc (GdkDrawable *drawable,
-                    GdkGC       *gc,
-                    gboolean     filled,
-                    gint         x,
-                    gint         y,
-                    gint         width,
-                    gint         height,
-                    gint         angle1,
-                    gint         angle2)
-{
-  CGContextRef context = gdk_quartz_drawable_get_context (drawable, FALSE);
-  float start_angle, end_angle;
-  gboolean clockwise = FALSE;
-
-  if (!context)
-    return;
-
-  _gdk_quartz_gc_update_cg_context (gc, drawable, context,
-                                   filled ?
-                                   GDK_QUARTZ_CONTEXT_FILL :
-                                   GDK_QUARTZ_CONTEXT_STROKE);
-
-  start_angle = angle1 * 2.0 * G_PI / 360.0 / 64.0;
-  end_angle = start_angle + angle2 * 2.0 * G_PI / 360.0 / 64.0;
-
-  /*  angle2 is relative to angle1 and can be negative, which switches
-   *  the drawing direction
-   */
-  if (angle2 < 0)
-    clockwise = TRUE;
-
-  /*  below, flip the coordinate system back to its original y-diretion
-   *  so the angles passed to CGContextAddArc() are interpreted as
-   *  expected
-   *
-   *  FIXME: the implementation below works only for perfect circles
-   *  (width == height). Any other aspect ratio either scales the
-   *  line width unevenly or scales away the path entirely for very
-   *  small line widths (esp. for line_width == 0, which is a hair
-   *  line on X11 but must be approximated with the thinnest possible
-   *  line on quartz).
-   */
-
-  if (filled)
-    {
-      CGContextTranslateCTM (context,
-                             x + width / 2.0,
-                             y + height / 2.0);
-      CGContextScaleCTM (context, 1.0, - (double)height / (double)width);
-
-      CGContextMoveToPoint (context, 0, 0);
-      CGContextAddArc (context, 0, 0, width / 2.0,
-                      start_angle, end_angle,
-                      clockwise);
-      CGContextClosePath (context);
-      CGContextFillPath (context);
-    }
-  else
-    {
-      CGContextTranslateCTM (context,
-                             x + width / 2.0 + 0.5,
-                             y + height / 2.0 + 0.5);
-      CGContextScaleCTM (context, 1.0, - (double)height / (double)width);
-
-      CGContextAddArc (context, 0, 0, width / 2.0,
-                      start_angle, end_angle,
-                      clockwise);
-      CGContextStrokePath (context);
-    }
-
-  gdk_quartz_drawable_release_context (drawable, context);
-}
-
 static void
 gdk_quartz_draw_polygon (GdkDrawable *drawable,
                         GdkGC       *gc,
@@ -529,7 +455,6 @@ gdk_drawable_impl_quartz_class_init (GdkDrawableImplQuartzClass *klass)
 
   drawable_class->create_gc = _gdk_quartz_gc_new;
   drawable_class->draw_rectangle = gdk_quartz_draw_rectangle;
-  drawable_class->draw_arc = gdk_quartz_draw_arc;
   drawable_class->draw_polygon = gdk_quartz_draw_polygon;
   drawable_class->draw_drawable_with_src = gdk_quartz_draw_drawable;
   drawable_class->draw_points = gdk_quartz_draw_points;
index 92fd843e1965cacb16e6e2c84566074e4e13aa02..72a01f65e42fad4f7e8bf925aa28746c01e9afc6 100644 (file)
@@ -55,15 +55,6 @@ static void gdk_win32_draw_rectangle (GdkDrawable    *drawable,
                                      gint            y,
                                      gint            width,
                                      gint            height);
-static void gdk_win32_draw_arc       (GdkDrawable    *drawable,
-                                     GdkGC          *gc,
-                                     gboolean        filled,
-                                     gint            x,
-                                     gint            y,
-                                     gint            width,
-                                     gint            height,
-                                     gint            angle1,
-                                     gint            angle2);
 static void gdk_win32_draw_polygon   (GdkDrawable    *drawable,
                                      GdkGC          *gc,
                                      gboolean        filled,
@@ -122,7 +113,6 @@ _gdk_drawable_impl_win32_class_init (GdkDrawableImplWin32Class *klass)
 
   drawable_class->create_gc = _gdk_win32_gc_new;
   drawable_class->draw_rectangle = gdk_win32_draw_rectangle;
-  drawable_class->draw_arc = gdk_win32_draw_arc;
   drawable_class->draw_polygon = gdk_win32_draw_polygon;
   drawable_class->draw_drawable_with_src = gdk_win32_draw_drawable;
   drawable_class->draw_points = gdk_win32_draw_points;
@@ -782,104 +772,6 @@ gdk_win32_draw_rectangle (GdkDrawable *drawable,
   cairo_region_destroy (region);
 }
 
-static void
-draw_arc (GdkGCWin32 *gcwin32,
-         HDC         hdc,
-         gint        x_offset,
-         gint        y_offset,
-         va_list     args)
-{
-  HGDIOBJ old_pen;
-  gboolean filled;
-  gint x, y;
-  gint width, height;
-  gint angle1, angle2;
-  int nXStartArc, nYStartArc, nXEndArc, nYEndArc;
-
-  filled = va_arg (args, gboolean);
-  x = va_arg (args, gint);
-  y = va_arg (args, gint);
-  width = va_arg (args, gint);
-  height = va_arg (args, gint);
-  angle1 = va_arg (args, gint);
-  angle2 = va_arg (args, gint);
-
-  x -= x_offset;
-  y -= y_offset;
-  
-  if (angle2 >= 360*64)
-    {
-      nXStartArc = nYStartArc = nXEndArc = nYEndArc = 0;
-    }
-  else if (angle2 > 0)
-    {
-      nXStartArc = x + width/2 + width * cos(angle1/64.*2.*G_PI/360.);
-      nYStartArc = y + height/2 + -height * sin(angle1/64.*2.*G_PI/360.);
-      nXEndArc = x + width/2 + width * cos((angle1+angle2)/64.*2.*G_PI/360.);
-      nYEndArc = y + height/2 + -height * sin((angle1+angle2)/64.*2.*G_PI/360.);
-    }
-  else
-    {
-      nXEndArc = x + width/2 + width * cos(angle1/64.*2.*G_PI/360.);
-      nYEndArc = y + height/2 + -height * sin(angle1/64.*2.*G_PI/360.);
-      nXStartArc = x + width/2 + width * cos((angle1+angle2)/64.*2.*G_PI/360.);
-      nYStartArc = y + height/2 + -height * sin((angle1+angle2)/64.*2.*G_PI/360.);
-    }
-  
-  if (filled)
-    {
-      old_pen = SelectObject (hdc, GetStockObject (NULL_PEN));
-      GDK_NOTE (DRAW, g_print ("... Pie(%p,%d,%d,%d,%d,%d,%d,%d,%d)\n",
-                              hdc, x, y, x+width, y+height,
-                              nXStartArc, nYStartArc, nXEndArc, nYEndArc));
-      GDI_CALL (Pie, (hdc, x, y, x+width, y+height,
-                     nXStartArc, nYStartArc, nXEndArc, nYEndArc));
-      GDI_CALL (SelectObject, (hdc, old_pen));
-    }
-  else
-    {
-      GDK_NOTE (DRAW, g_print ("... Arc(%p,%d,%d,%d,%d,%d,%d,%d,%d)\n",
-                              hdc, x, y, x+width, y+height,
-                              nXStartArc, nYStartArc, nXEndArc, nYEndArc));
-      GDI_CALL (Arc, (hdc, x, y, x+width, y+height,
-                     nXStartArc, nYStartArc, nXEndArc, nYEndArc));
-    }
-}
-
-static void
-gdk_win32_draw_arc (GdkDrawable *drawable,
-                   GdkGC       *gc,
-                   gboolean     filled,
-                   gint         x,
-                   gint         y,
-                   gint         width,
-                   gint         height,
-                   gint         angle1,
-                   gint         angle2)
-{
-  GdkRectangle bounds;
-  cairo_region_t *region;
-
-  GDK_NOTE (DRAW, g_print ("gdk_win32_draw_arc: %s  %d,%d,%d,%d  %d %d\n",
-                          _gdk_win32_drawable_description (drawable),
-                          x, y, width, height, angle1, angle2));
-
-  if (width <= 2 || height <= 2 || angle2 == 0)
-    return;
-
-  bounds.x = x;
-  bounds.y = y;
-  bounds.width = width;
-  bounds.height = height;
-  region = widen_bounds (&bounds, GDK_GC_WIN32 (gc)->pen_width);
-
-  generic_draw (drawable, gc,
-               GDK_GC_FOREGROUND | (filled ? 0 : LINE_ATTRIBUTES),
-               draw_arc, region, filled, x, y, width, height, angle1, angle2);
-
-  cairo_region_destroy (region);
-}
-
 static void
 draw_polygon (GdkGCWin32 *gcwin32,
              HDC         hdc,
index 5eff383a9b7fdd69089e899d9c6f00af2cf26c5a..be63bcc59643294c5fbba67616a5f4984b722485 100644 (file)
@@ -55,15 +55,6 @@ static void gdk_x11_draw_rectangle (GdkDrawable    *drawable,
                                    gint            y,
                                    gint            width,
                                    gint            height);
-static void gdk_x11_draw_arc       (GdkDrawable    *drawable,
-                                   GdkGC          *gc,
-                                   gboolean        filled,
-                                   gint            x,
-                                   gint            y,
-                                   gint            width,
-                                   gint            height,
-                                   gint            angle1,
-                                   gint            angle2);
 static void gdk_x11_draw_polygon   (GdkDrawable    *drawable,
                                    GdkGC          *gc,
                                    gboolean        filled,
@@ -118,7 +109,6 @@ _gdk_drawable_impl_x11_class_init (GdkDrawableImplX11Class *klass)
   
   drawable_class->create_gc = _gdk_x11_gc_new;
   drawable_class->draw_rectangle = gdk_x11_draw_rectangle;
-  drawable_class->draw_arc = gdk_x11_draw_arc;
   drawable_class->draw_polygon = gdk_x11_draw_polygon;
   drawable_class->draw_drawable_with_src = gdk_x11_draw_drawable;
   drawable_class->draw_points = gdk_x11_draw_points;
@@ -340,30 +330,6 @@ gdk_x11_draw_rectangle (GdkDrawable *drawable,
                    GDK_GC_GET_XGC (gc), x, y, width, height);
 }
 
-static void
-gdk_x11_draw_arc (GdkDrawable *drawable,
-                 GdkGC       *gc,
-                 gboolean     filled,
-                 gint         x,
-                 gint         y,
-                 gint         width,
-                 gint         height,
-                 gint         angle1,
-                 gint         angle2)
-{
-  GdkDrawableImplX11 *impl;
-
-  impl = GDK_DRAWABLE_IMPL_X11 (drawable);
-
-  
-  if (filled)
-    XFillArc (GDK_SCREEN_XDISPLAY (impl->screen), impl->xid,
-             GDK_GC_GET_XGC (gc), x, y, width, height, angle1, angle2);
-  else
-    XDrawArc (GDK_SCREEN_XDISPLAY (impl->screen), impl->xid,
-             GDK_GC_GET_XGC (gc), x, y, width, height, angle1, angle2);
-}
-
 static void
 gdk_x11_draw_polygon (GdkDrawable *drawable,
                      GdkGC       *gc,